package com.njworkorder.VO;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.util.List;


@Data
public class AMCVo {
    @Schema(description = "本年费用")
    private double thisYearsExpenses = 0;
    @Schema(description = "往年费用")
    private double previousYearExpenses = 0;
    @Schema(description = "相差")
    private double phaseDifference;

    private List<AMCData> amcDataList;

    public void calculatePhaseDifference() {
        this.phaseDifference = Math.abs(thisYearsExpenses - previousYearExpenses);
    }

}